package com.example.demo.mapping;

import com.example.demo.domain.model.User;
import com.example.demo.domain.query.UserCreateQuery;

import com.example.demo.domain.query.UserStatusQuery;
import com.example.demo.domain.query.UserUpdateQuery;
import org.mapstruct.Mapper;
import org.mapstruct.factory.Mappers;
@Mapper
public interface UserMapping {
    UserMapping INSTANCE = Mappers.getMapper(UserMapping.class);

     //plus添加类转换
     User toCreate (UserCreateQuery userCreateQuery);
     //plus更新参数转化
     User toUpdate(UserUpdateQuery userUpdateQuery);
     //plus更新用户的黑名单状态
     User toStatus(UserStatusQuery userStatusQuery);
}
